package cn.adelyn.blog.api.file.feign;

import cn.adelyn.common.core.response.ServerResponseEntity;
import cn.adelyn.common.feign.config.FeignInsideAuthConfig;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.RequestBody;

import jakarta.validation.constraints.NotEmpty;
import java.util.List;

@Validated
@FeignClient(value = "adelyn-blog-file", contextId ="pic", path = "/blog/oss")
public interface PicFeignClient {

    /**
     * 删除图片
     */
    @DeleteMapping(FeignInsideAuthConfig.FEIGN_URL_PREFIX + "/pic")
    ServerResponseEntity deletePic(@RequestBody @NotEmpty(message = "picId list 不能为空~") List<Long> picId);
}
